package com.tupu.service.dispatch;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.tupu.common.PageResult;
import com.tupu.entity.dispatch.StandardizationNameStandard;
import com.tupu.entity.dispatch.StandardizationPoint;
import com.baomidou.mybatisplus.extension.service.IService;
import com.tupu.entity.dto.StandardizationPointDTO;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.time.LocalDateTime;
import java.util.List;
import java.util.Map;

/**
 * @author 15702
 * @description 针对表【tb_standardization_point】的数据库操作Service
 * @createDate 2023-11-10 10:56:58
 */
public interface StandardizationPointService extends IService<StandardizationPoint> {

    Page<StandardizationPoint> pointSignalPage(String station, String pointName, String validResult, Long page, Long size);

    void validPointData(LocalDateTime startTime, LocalDateTime endTime);

    Map<String, Object> pointTypePercentage(String station, String messageType, String checkResult, LocalDateTime startTime, LocalDateTime endTime);

    Map<String, Object> resultPercentage(String station, String messageType, String checkResult, LocalDateTime startTime, LocalDateTime endTime);

    List<String> standardizationDeviceTypeList();

    List<String> standardizationStationList(String station);

    void downloadExcelDemo(HttpServletResponse response);

    Map<String, Object> standardizationDeviceImport(MultipartFile file, HttpServletResponse response);

    void downloadCheckResult(String fileId, HttpServletResponse response);

    void exportExcel(HttpServletResponse response, String station, String deviceType, String validResult, LocalDateTime startTime, LocalDateTime endTime) throws IOException;

    List<String> deviceStandardList();

    List<String> deviceDescList(String deviceName);

    PageResult<StandardizationNameStandard> nameDescList(Long page, Long size, String name);

    void addNameDesc(StandardizationNameStandard nameStandard);

    void updateNameDescByIds(StandardizationNameStandard nameStandard);

    void DelNameDescByIds(String ids);

    void updateDeviceStandard(Integer problemId, String standardName, String standardDesc);

    String train(Integer problemId);

    PageResult<StandardizationPointDTO> dailyTraining(Integer page, Integer size, String time, String pointName);

    void analysisT0007(Integer C0007_POINT_ID) throws IllegalAccessException;

    void analysisTimingT0007();

    void updateValidResult(Integer problemId, String validResult);

    void ModelAnalysisTiming() throws IllegalAccessException;
}
